//
//  SYpublicViewController.m
//  快医
//
//  Created by Eric on 16/7/8.
//
//

#import "SYpublicViewController.h"
#import "XHRCategoryView.h"
#import <SVProgressHUD.h>
@interface SYpublicViewController ()<UIWebViewDelegate>

@end

@implementation SYpublicViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    self.navigationItem.title= @"公益";
    
    
    [self.navigationController.navigationBar setTintColor:[UIColor blackColor]];
 
    [self loadWebView];
}

- (void)loadWebView{

    UIWebView *webview = [[UIWebView alloc] init];
    
    NSString *urlString = @"http://202.106.210.115:18080/hyde-pluto-h360/nt/appEntrance.htm";
    
    NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:urlString]];
    
    webview.delegate = self;
    
    [webview loadRequest:request];
    
    [self.view  addSubview:webview];
    
    [webview makeConstraints:^(MASConstraintMaker *make) {
        
        make.top.bottom.left.right.offset(0);
  
    }];
    
//    [SVProgressHUD setMinimumDismissTimeInterval:0.7];
//    
//    [SVProgressHUD showSuccessWithStatus:@"正在加载"];
//    
//    [SVProgressHUD setDefaultMaskType:SVProgressHUDMaskTypeBlack];

}

- (void)webViewDidStartLoad:(UIWebView *)webView{
    
    [SVProgressHUD showWithStatus:@"正在加载"];
    
    
}
- (void)webViewDidFinishLoad:(UIWebView *)webView{
    
    [SVProgressHUD dismiss];
}





@end
